1. Field of the Invention
The present invention relates to a method of generating range images and an apparatus therefor, and more particularly to a method of generating range images by generating range images by using a stereo matching technique or the like and an apparatus therefor.
2. Description of the Related Art
As a range image generating apparatus, what generates range images by using a stereo matching technique is generally known. By a stereo matching technique, a set of stereo images are obtained by shooting subjects in the same spatial area with a plurality of image sensors (e.g. two image sensors) in different directions of the line of sight. When stereo images are obtained, the position of the image point on each stereo image for the same object point of a subject is detected as one or the other of corresponding points between the images, and the lag (parallax) between the corresponding points on the different images is detected. On the basis of this parallax, the distance to that object point is figured out according to the principle of trigonometry. By applying this processing to each object point of the subject, a range image the values of whose pixels are the distances to the different object points of the subject is generated.
A range image generating apparatus using such a stereo matching technique requires matching between the pixels of different images by detecting on each of the obtained stereo images image points matching the same object point of the subject as corresponding points. This detection of corresponding points has been accomplished by detecting characteristic parts of the subject appearing on each image, utilizing features of the pattern of the subject and the like. However, where the pattern of the subject is poor in contract such as monotone, it has few characteristic parts, thereby it may be difficult to adequately match pixels in different images. In view of this problem, it is proposed in Japanese Patent Application Laid-Open No. 2001-8235, Japanese Patent Application Laid-Open No. 2001-194114, Japanese Patent Application Laid-Open No. 2001-264033 and Japanese Patent Application Laid-Open No. 2003-121126 to facilitate detection of corresponding points even from a subject having only a few characteristic parts by irradiating the subject with infrared rays of a prescribed pattern and obtaining stereo images shot with those infrared rays and thereby to make it possible to adequately match pixels in the different images.